4. bottle filling and capping machine 4

好的,那么继续我们的 Curda,我们实际上需要想出一个系统来管理这样一个事实:当产品低于时,我们可能需要赶上使用封盖站或灌装站或两者。
OK, so moving on with our Curda, we needed to actually come up with a system to manage the fact that we may either need to catch up to use the capping station or the filling station or both when a product comes below.

所以我们在这里可以做什么,当我们收到触发信号时,如果我们收到加油站的触发信号,我们实际上可以在这里做。
So what we can do here, when we receive the trigger, we can actually right here that if we receive the trigger for the filling station.

因此,如果我们触发产品在加油站排队,那么我们的感觉状态。
So if our trigger product on filling station they are to queue, then our feeling state.

我们需要设置为零,这意味着我们需要运行整个状态机才能执行感觉,否则,我们的感觉状态实际上已经设置为 100。
We'll need to be set equal to zero, this means that we need to run through the whole state machine in order to to perform the feeling else, our feeling state can be actually already be set at 100.

这样,状态机将在完成状态下启动,因此它不会执行任何操作。
In this way, the state machine will start already in the finished state, so it won't do anything.

同样,封盖站也需要发生同样的事情,因此,如果我们的三个产品开盖站,则封盖状态应等于 0,否则封盖状态应等于 100。
Again, the same thing needs to happen for the capping station, so our right if our three product uncapping station, then the capping state should be equal to zero else the capping state should be equal to 100.

好的,现在我建议您在这里,我建议使用一些操作以更紧凑的方式编写此内容。
OK, now I suggest to you then over here, I suggested to write this in a more compact way, using some actions.

因此,在对话中,这次我收到了一条动作指导文本,表示我将调用呼叫加油站状态机。
So here in the conversation, I had an action instructor text this time that I would call the call filling station state machine.

我将简单地复制此代码,即此处的加油站代码。
And I will simply copy this code, the filling station code over here.

在动作中,这里我将动作称为加油站状态机,这样人群将意味着更加紧凑并与其他部分分开。
In the action and here I will call the action filling station state machine, and this way the crowd will mean more of a compact and separated from the other parts.

它将更容易阅读和调试。
It will be way more easy to read and debug.

我会的,封盖站也是如此。
The same goes over here for the capping station, I will.

切熟练了,我会在S.T.这里添加一个动作。
Cut the skilled, I will add an action here in S.T..

这将是封盖站,状态机。
And this will be the capping station, state machine.

是套件中的代码吗?从功能上来说,这与之前的代码相同,但在我看来,它组织得更好,保留了站状态机。
Is the code here in the suite, this, functionally speaking, is the same thing that was the code before, but it is better organized, in my opinion, keeping station state machine.

好的,那么当我们到达这里时,我们的状态都等于 10,这意味着我们要么完成了上限,要么感觉良好。
OK, then when we reach here, we have both of our state equal to ten, meaning that we finished either capping or feeling good.

然后我们实际上可以回到我们当时看到的状态。
Then we actually can go back to state then in which we look.

我们检查是否有一些产品,如果有一些产品,我们可以移动传送带。
We checked to see if there are some products and if there are some products, we can move the conveyor.

好的,我们到这里就差不多完成了。
OK, so we are almost done over here.

我们需要管理其他一些事情。
We need to manage a few other things.

我们还需要另一个项目,这意味着当我们按下紧急停止按钮时,我们实际上需要禁用所有通用设备。
They are we need also the other project, meaning that when we when an emergency stop is pressed, we actually need to disable all the generic devices.

所以这里我就简单的复制这部分代码。
So here I will simply copy this part of the code.

因此,我们在这里启用通用设备的部分,当我们按下紧急按钮时,我们需要禁用它们。
So the part where we enable the generic devices here, when we press emergency, we need to disable them.

因此,我们对所有通用设备的权利都属于这里。
So our right falls here for all the generic devices.

然后我们还需要管理停止状态和整个状态。
Then we need to manage the stopping state and the whole state as well.

我的意思是,整个状态可以与我们在其他状态机中实际管理的状态相同。
I mean, the whole state can be the same one that we actually managed in our other state machines.

所以实际上我们可以复制那部分。
So actually we can copy that part.

所以我们会骑它。
So we will ride it.

在这里,但我也会将其复制到机器人站的模板中,所以这里是正确的孔,有 500 个,在我们的整个状态中,如果我们没有整个输入,那么我们的状态应该成为整个状态,而整个状态应该成为实际的整个状态已经在这部分代码中进行管理。
Here, but I will also copy this in the template for the robot station, so here are the right holes that there is 500 and in our whole state, if we don't have the whole input, then our state should become the whole state, while the whole state should become the actual whole state is already managed in this part of the code down here.

因此,您也可以在此处的机器人站中简单地复制此内容。
So you could simply copy this as well in the robot station here.

所以我们已经写好了。
So we have we will have that already written.

然后我们需要管理设备的启动。
Then we need to manage the start up of the devices.

所以如果我们的设备如果我们收到一个停止操作,那么停止命令,我们就会进入停止状态和停止状态。
So if our device if we receive a stop operation, so stop command, we will get to the state stopping state and the state.

我们确实需要停止输送机,因此输送机装置应设置为强制。
We need surely to stop the conveyor so conveyor device that device and should be set to force.

我们还需要停止感觉设备,该设备命令也应该称为假 DIPP 封顶。
We need to stop also the feeling feeling device, that device command should be called the false DIPP capping as well.

应等于四。
Should be equal to four.

应该停止和。
Should be stopped and.

实际上,我们还需要管理设备公司应该能够强制执行的封盖移动设备,在这里我们应该等待所有设备实际停止。
Actually, we will need to also manage the capping movement device that device companies should be able to force, and right here we should wait for all of our devices to be actually stopped.

所以实际上,在我们的,呃。
So actually, in our, uh.

你看这里,是的,这很好。
And you see here, yeah, this is fine.

因此,我们将等待所有这些设备处于禁用状态。
So we will wait for all these devices to be there in the state disabled.

因此,输送装置、该装置状态等于禁用,以及感觉装置、该装置状态等于禁用、并且封盖装置通过状态等于禁用、并且封盖运动装置、该装置状态等于等于禁用。
So conveyer device, that device state equal to disabled and feeling device, that device state equal to disabled and the capping device by state equal to disabled and the capping movement device that device state is equal equal to disabled.

然后我实际上会将其放在贯穿线中,以便如果所有这些都更容易阅读。
Then I will actually place this on through lines in order to have it a little bit more easy to read if all of this are.

停止就是禁用的,我们可以回到零。
Stopped are disabled and we can get back to zero.

好的。
OK.

我们需要研究的另一件事是我们不希望旧过程发生的状态。
Another thing that we need to look into are the states in which we don't want the old procedure to occur.

那么让我们考虑一下各州。
So let's think about the states.

事实上,对于我们来说,在输送机移动时以及在进行护理灌装或封盖时,握持是相当复杂的。
Actually, for us, it is quite complicated to hold when the conveyor is moving and also when the care filling or capping is happening.

所以我们要写的是state不应该等于20,不应该等于。
So what we will write is that the state should not be equal to 20, should not be equal.

到,呃。
To, uh.

三十,因为三十了,传送带还在动。
Thirty, because in 30, the conveyor is still moving.

40 就可以了,因为这是传送带停止的地方。
And 40 is OK because this is where the conveyor is stopping.

而且,呃,50 也是不行的,因为有流量,有上限。
And, uh, also 50 is not OK, because there is the flow going, there is the capping working.

因此,我们正确地说,州数不应等于 20、不应等于 30、也不应等于 50。
So let's right that the states should not be equal to 20, should not be equal to 30 and should not be equal to 50.

好的,我们也会在这里,对吧?
OK, so here we will also, right?

在下面,说明不等于 20,说明不等于 30,说明不等于 50。
Here down below and state, not equal to 20 and state not equal to 30 and state not equal to 50.

好的。
OK.

这对我们来说很好。
This is fine for us.

我想我们已经涵盖了有关我们站的所有内容,我们实际上可以上网看看这个站是否正常工作。
I guess we covered everything concerning our station and we can actually get online and see if this station is working.

我们上网吧。
Let's go online and.

执行下载。
Carry out to download.

让我们启动我们的程序,让我们尝试启动我们的机器。
Let's start our program and let's try let's try to start our machine.

好的,开始生产已经完成,我们需要看到一些洞穴,好的,传送带正在移动,传送带停止了,它发生得相当快。
OK, start producing the is through, we will need to see some burrows, OK, the conveyor is moving, the conveyor stopped, it is happening quite fast.

好吧,现在我们感觉不太好,有什么地方不对劲。
OK, right now we are feeling without OK, something is wrong.

我们可以看到封盖站已经停在这里了。
We can see the capping station has stopped here.

那么我们就离线吧。
So let's go offline.

封盖站状态机。
Capping station state machine.

让我们看看,让我们保持在那个场景中的线路,我们被困在哪个状态。
Let's see, so let's remain on the line in that scene, which state we are stuck.

好吧,看来好吧,定时器没有完成,好吗?
OK, it seems that OK, that the timer doesn't get it through, OK?

是的,当然,我没有在这里添加对计时器的调用。
Yes, of course, I didn't add the call for the timer over here.

我只添加了对计时器感觉的调用。
I only added the call for the timer feeling it.

我还需要调用计时器上限。
I also needed the call for the timer capping.

好的,让我们再试一次。
OK, so let's try this again.

让我们上网下载吧。
Let's go online with the download.

这是 PRC 的开始,让我们按下这里的开始按钮,好的,第一个瓶子已正确填充,正在盖上盖子,然后我们继续。
That's for a start to the PRC and let's press the start button over here, OK, the first bottle is being filled correctly, is being capped, and then we move on.

好的,第二个按钮正在填充。
OK, second button is being filled.

好的,看起来工作得很好。
OK, it seems to be working quite fine.

我们机器人正在移动。
We the robot is moving.

因此,我们实际为模拟制作的底部,传送带上最多可以有五个物体。
So the bottom we actually make for the simulation, we can have up to five bodies on the conveyors.

所以它们实际上会堆积在传送带的末端。
So they will actually pile up at the end of the conveyor.

但这对我们来说似乎效果很好。
But this seems to be working quite fine for us.

所以这很好。
So this is good.

这真是太好了。
This is really good.

和。
And.

我们实际上可以停止并重新开始并尝试一些保留程序,所以我现在会尝试,我将删除旧的。
We can actually stop and start again and try some hold procedures, so I will try just now, I will remove the old.

好吧,这就是我们被困在那里的原因,我们来看看为什么。
OK, this is something we are stuck there us see why.

我们抓了500人,但我们并不老,但全身都被移走了,旧的输入仍然如此。
We arrested 500, but we are not not old, but the old input is still true while the whole body is removed.

让我调查一下,这可能是一个主要的程序问题,因为我们逮捕了 500 人。
Let me look into this, maybe a main program issue because we arrested 500.

哦,是的,是的,这是因为我们的机器人静止状态还没有运行。
Oh, yes, yes, this is due to the fact that our robot stationary is still not running.

所以来自机器人站的所有部分现在都不会发生。
So all of the part coming from the robot station will not occur right now.

现在,让我们在这里插入一些评论。
So for now, let's insert some comments over here.

所以这里我就在这里补充一下评论,我们就补充一下。
So here I will add a comment here and we'll add it.

然后,当我们让机器人站工作时,我们将删除它。
Then we will remove this when we get the robot station working.

所以这个和这个。
So this and this.

好的,让我们重新上线吧。
OK, so let's get back online.

操作应该已经恢复。
The operation should have been resumed.

又是这样。
That's all again.

好吧,我们就到此为止吧。
OK, so let's stop there.

让我们把旧的凸版印刷机再次变旧。
Let's move the old letterpress old again.

好的,等等。
OK, hold.

我们再坚持一下,好吗?
Let's hold again, OK?

是的,是的,它似乎工作正常,现在似乎工作得很好。
Yep, yep, it seems to work the old right now seems to work fine.

让我们尝试在机器工作时停止,所以让我们尝试在这里停止,它可以工作。
And let's try a stop when the machine is working, so let's try to stop here, it works.

于是传送带停止了。
So the conveyor stops.

又在这里,又在这里。
That's right here again, here again.

是的,把这台机器包起来,其实停车和紧急情况很相似。
Yes, enfolded this machine, actually, the stop is quite similar to the emergency.

所以这里的紧急情况也是如此。
So the emergency here works in the same way.

我们重来。
Let's start again.

当我们在车站下面有一些瓶子时尝试紧急情况,好吗?
And try an emergency when we have some bottles below the stations here, OK?

是的,紧急停止和旧的似乎都工作正常,这很好。
Yes, the both the emergency stop and old seemed to work OK, this is fine.

所以现在,我们可以转到橡胶站,我们将为该站实施一切,然后我们就可以进行诊断部分了。
So right now, we can move on to the rubber station and we will implement everything for the station and then we will be good to go for the diagnosis part.